package com.JWH_TV.api

import com.JWH_TV.api.domain.AddDeviceResponse
import com.JWH_TV.api.domain.ApiResponse
import com.JWH_TV.api.domain.RegistrationTokenResponse
import com.JWH_TV.domain.DeviceExternallyAddedDTO
import com.JWH_TV.domain.LiveListVO
import retrofit2.Call
import retrofit2.http.*

interface ApiService {

    // 获取每个分类下的节目列表接口
    @GET("/live/getLiveList")
    fun getLiveList(@Header("token") token: String, @Header("timestamp") timestamp: String): Call<ApiResponse>

    // 获取设备注册令牌
    @GET("/devices/registrationToken/{mac}")
    fun getRegistrationToken(@Path("mac") macAddress: String): Call<RegistrationTokenResponse>

    @POST("/devices/externallyAdded")
    fun addDevice(
        @Body dto: DeviceExternallyAddedDTO,
        @Header("Authorization") token: String
    ): Call<AddDeviceResponse>
}